//
//  BanBu_SnowView.h
//  Snow
//
//  Created by Wang Xj on 14-2-21.
//  Copyright (c) 2014年 BanBu. All rights reserved.
//

#import <UIKit/UIKit.h>
#import <AVFoundation/AVFoundation.h>
#import <MediaPlayer/MediaPlayer.h>

@protocol SnowViewDelegate;

@interface BanBu_SnowView : UIView<AVAudioPlayerDelegate>
{
    NSMutableArray *_imagesArray;
}

@property (assign, nonatomic) id<SnowViewDelegate>delegate;

-(void)initWithImagePath:(NSString *)imagePath musicName:(NSString *)musicPath;

@property (strong, nonatomic) NSString * imageName;
@property (strong, nonatomic) NSString * musicName;

@property (strong, nonatomic) NSTimer * timer;
@property (retain, nonatomic) AVAudioPlayer * audioPlayer; //播放发送时的声音

@property (weak, nonatomic) IBOutlet UIButton *start;
- (IBAction)statrOrStop:(UIButton *)sender;

@end

@protocol SnowViewDelegate <NSObject>

-(void)didFinishPlayingSnows:(BanBu_SnowView *)snowView;

@end
